// 获取会员分页
const getPetShopMemberPage = (params) => {
    return $axios({
        url: '/member/page',
        method: 'get',
        params
    })
}

// 新增会员接口
const addMember = (params) => {
    return $axios({
        url: '/member',
        method: 'post',
        data: {...params}
    })
}

// 修改会员信息接口
const editMember = (params) => {
    return $axios({
        url: '/member',
        method: 'put',
        data: {...params}
    })
}

// 根据 id 查询一个会员
function queryMemberById(id) {
    return $axios({
        url: `/member/${id}`,
        method: 'get'
    })
}

// 获取会员消费记录
function getCostRecordList(params) {
    return $axios({
        url: '/cost/page',
        method: 'post',
        data: {...params}
    })
}

// 添加一条业务记录
function addMemberRecord(params) {
    return $axios({
        url: '/cost/addMemberRecord',
        method: 'post',
        data: {...params}
    })
}

// 删除接口
const deleteMembers = (ids) => {
    return $axios({
        url: '/member',
        method: 'delete',
        params: { ids }
    })
}
